﻿//using Azure.Core;
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Filters;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.Extensions.DependencyInjection;
namespace Proxies.Filter
{
    public class FilterFile : Attribute, IResourceFilter
    {
        //public override void OnActionExecuting(ActionExecutingContext context)
        //{
        //    string url = context.HttpContext.Request.Headers["url"];
        //    if(url.IndexOf("mojang")==-1 && url.IndexOf("minecraft.net") == -1)
        //    {
        //        context.Result = new JsonResult(
        //            //该类是KeeSoft框架里自带的一个返回结果集
        //            "message","请求非法"
        //        );
        //        return;
        //    }

        //}
        public void OnResourceExecuted(ResourceExecutedContext context)
        {
            throw new NotImplementedException();
        }

        public void OnResourceExecuting(ResourceExecutingContext context)
        {
            throw new NotImplementedException();
        }
    }
}
